﻿namespace DimensionsHelper.LanguageService.Syntax;

public class MetadataProperties : MetadataListWithAreal<MetadataProperty>
{
    internal MetadataProperties(SyntaxNode? parent) :
        base(SyntaxKinds.MetadataProperties, parent)
    {
    }
}


public static partial class NodeFactory
{
    public static MetadataProperties CreateMetadataProperties(SyntaxNode? parent, Identifier? arealName,
        IEnumerable<MetadataProperty>? properties)
    {
        MetadataProperties list = new(parent);
        if (!Identifier.IsDefaultOrEmpty(arealName))
        {
            list.Update(arealName);
        }

        return InitializeMetadataListWithAreal(list, properties);
    }
}